Embed Authentication

Before the embedding framework is functional, it needs to connect to Pyramid to retrieve the content. This connection needs to be authenticated. Authentication is performed by programmatically logging in as a specific Pyramid user using Pyramid REST security API and saving the authentication token into a local cookie.

NOTE: This code can be called from any technology that supports a RESTful service. However, we recommend that it remain as hidden or compiled code since it involves an authentication processes.

Embed API Authentication

The Embed APIs offer JavaScript enacted authentication - generally only appropriate for modern 'single-page' web applications built with JavaScript, React or Angular. However, the APIs are simply a facade for Pyramid security REST APIs in the end.

Examples

Review the examples below for C#, Java, and raw JavaScript.

  • The URL is the address of your main Pyramid installation.
  • The user provided must be a Pyramid user.
  • The domain is not required unless using Active Directory as your authentication provider in Pyramid

.